Optimal. Leaf size=27 \[ \frac{B \sin (c+d x) \cos (c+d x)}{2 d}+\frac{B x}{2} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0145795, antiderivative size = 27, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 34, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.088, Rules used = {21, 2635, 8} \[ \frac{B \sin (c+d x) \cos (c+d x)}{2 d}+\frac{B x}{2} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 21
Rule 2635
Rule 8
Rubi steps
\begin{align*} \int \frac{\cos ^2(c+d x) (a B+b B \cos (c+d x))}{a+b \cos (c+d x)} \, dx &=B \int \cos ^2(c+d x) \, dx\\ &=\frac{B \cos (c+d x) \sin (c+d x)}{2 d}+\frac{1}{2} B \int 1 \, dx\\ &=\frac{B x}{2}+\frac{B \cos (c+d x) \sin (c+d x)}{2 d}\\ \end{align*}
Mathematica [A] time = 0.0201968, size = 24, normalized size = 0.89 \[ \frac{B (2 (c+d x)+\sin (2 (c+d x)))}{4 d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.053, size = 28, normalized size = 1. \begin{align*}{\frac{B}{d} \left ({\frac{\cos \left ( dx+c \right ) \sin \left ( dx+c \right ) }{2}}+{\frac{dx}{2}}+{\frac{c}{2}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.50298, size = 61, normalized size = 2.26 \begin{align*} \frac{B d x + B \cos \left (d x + c\right ) \sin \left (d x + c\right )}{2 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 1.14062, size = 68, normalized size = 2.52 \begin{align*} \begin{cases} \frac{B x \sin ^{2}{\left (c + d x \right )}}{2} + \frac{B x \cos ^{2}{\left (c + d x \right )}}{2} + \frac{B \sin{\left (c + d x \right )} \cos{\left (c + d x \right )}}{2 d} & \text{for}\: d \neq 0 \\\frac{x \left (B a + B b \cos{\left (c \right )}\right ) \cos ^{2}{\left (c \right )}}{a + b \cos{\left (c \right )}} & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.5728, size = 45, normalized size = 1.67 \begin{align*} \frac{{\left (d x + c\right )} B + \frac{B \tan \left (d x + c\right )}{\tan \left (d x + c\right )^{2} + 1}}{2 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]